all: exacto constructiva busq_local tabu

exacto: exacto.cpp
	@echo "compilando exacto.."
	@g++ exacto.cpp -o exacto
constructiva: constructiva.cpp
	@echo "compilando constructiva.."
	@g++ constructiva.cpp -o constructiva
busq_local: busq_local.cpp
	@echo "compilando busqueda local.."
	@g++ busq_local.cpp -o busq_local
tabu: tabu.cpp
	@echo "compilando tabu search.."
	@g++ tabu.cpp -o tabu

hard.in: instance.py
	@echo "generando instancias de prueba.."
	@./instance.py

hard_big.in: instance_big.py
	@echo "generando instancias grandes de prueba.."
	@./instance_big.py

compare: data.dat
compare_big: data_big.dat

data.dat: compare.py hard.in exacto.out constructiva.out busq_local.out tabu.out
	@echo "formateando data.."
	@./compare.py

data_big.dat: compare_big.py hard_big.in constructiva_big.out busq_local_big.out tabu_big.out
	@echo "formateando data.."
	@./compare_big.py

%.out: % hard.in
	@echo "poniendo a prueba $<.."
	@./$^ < hard.in > $@

%_big.out: % hard_big.in
	@echo "poniendo a prueba $<.."
	@./$^ < hard_big.in > $@

clean:
	@rm -f hard.in data.dat exacto constructiva busq_local tabu exacto.out constructiva.out busq_local.out tabu.out
	@echo "clean ;)"
